package com.xm.po;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;
/**
* @Description: 订单实体类
* @Author: Mr.Wang
* @Date: 2020/8/6
*/
public class Order {
    //属性
    private Integer orderId;
    //订单编号
    private String orderNo;
    //-2:未付款的订单 -11:未付款关闭订单 <br/> 0:未受理<br/> -1：用户取消(未受理前-店铺未读)<br/> -8:用户取消(未受理前-店铺已读)<br/> 1:已受理<br/> -6:用户取消(已受理-店铺未读)<br/> -7:用户取消(已受理-店铺已读)<br/> 2:打包中 <br/> -9:用户取消(打包中-店铺未读)<br/> -10:用户取消(打包中-店铺已读) <br/> 3:配送中 <br/> -3:用户取消(配送中-店铺未读)<br/> -4:门店同意退款 (配送中取消-店铺已读【已退款】)<br/> -5:门店不同意退款 (配送中取消-店铺已读)<br/> 4:用户确认收货
    private Integer orderStatus;
    //商品总金额
    private Double totalMoney;
    //订单运费
    private Double deliverMoney;
    //支付方式 0线上支付 1货到付款
    private Integer payType;
    //是否自提
    private Integer isSelf;
    //是否支付 0未付 1已付
    private Integer isPay;
    //配送方式 0:商城配送 1:门店配送
    private Integer deliverType;
    //收货地址编号
    private Integer userAddressId;
    //本次订单所得积分
    private Integer orderScore;
    //是否需要发票 0不需要 1需要
    private Integer isInvoice;
    //发票抬头
    private String invoiceClient;
    //订单备注
    private String orderRemarks;
    //是否点评 0未点评 1已点评
    private Integer isAppraises;
    //下单时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
    //是否订单完结
    private Integer isClosed;
    //是否退款 0否 1是
    private Integer isRefund;
    //退款说明
    private String refundRemark;
    //订单唯一流水号
    private String orderunique;
    //订单来源 0商城 1微信 2手机版
    private Integer orderSrc;
    //订单有效标志 -1删除 1有效
    private Integer orderFlag;
    //在线交易支付流水
    private String tradeNo;
    //支付来源 1支付宝 2微信 3银行卡
    private Integer payFrom;
    //结算记录ID
    private Integer settlementId;
    //实际订单总金额
    private Double realTotalMoney;
    //本次订单所使用的积分
    private Integer useScore;
    //积分抵扣的金额
    private Double scoreMoney;
    //收货时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date receiveTime;
    //发货时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date deliveryTime;
    //优惠券金额
    private Integer couponMoney;
    //退款金额
    private Double backMoney;
    //退款前订单状态
    private Integer refundSrcStatus;
    //订单来源 1:普通订单 2：团购订单 3：抢购订单
    private Integer orderFrom;

    //构造器
    public Order() {
    }

    public Order(String orderNo) {
        this.orderNo = orderNo;
    }

    public Order(String orderNo, Integer userAddressId, String orderRemarks, Double totalMoney) {
        this.orderNo = orderNo;
        this.userAddressId = userAddressId;
        this.orderRemarks = orderRemarks;
        this.totalMoney = totalMoney;
    }

    public Order(Integer orderId, String orderNo, Integer orderStatus, Double totalMoney, Double deliverMoney, Integer payType, Integer isSelf, Integer isPay, Integer deliverType, Integer userAddressId, Integer orderScore, Integer isInvoice, String invoiceClient, String orderRemarks, Integer isAppraises, Date createTime, Integer isClosed, Integer isRefund, String refundRemark, String orderunique, Integer orderSrc, Integer orderFlag, String tradeNo, Integer payFrom, Integer settlementId, Double realTotalMoney, Integer useScore, Double scoreMoney, Date receiveTime, Date deliveryTime, Integer couponMoney, Double backMoney, Integer refundSrcStatus, Integer orderFrom) {
        this.orderId = orderId;
        this.orderNo = orderNo;
        this.orderStatus = orderStatus;
        this.totalMoney = totalMoney;
        this.deliverMoney = deliverMoney;
        this.payType = payType;
        this.isSelf = isSelf;
        this.isPay = isPay;
        this.deliverType = deliverType;
        this.userAddressId = userAddressId;
        this.orderScore = orderScore;
        this.isInvoice = isInvoice;
        this.invoiceClient = invoiceClient;
        this.orderRemarks = orderRemarks;
        this.isAppraises = isAppraises;
        this.createTime = createTime;
        this.isClosed = isClosed;
        this.isRefund = isRefund;
        this.refundRemark = refundRemark;
        this.orderunique = orderunique;
        this.orderSrc = orderSrc;
        this.orderFlag = orderFlag;
        this.tradeNo = tradeNo;
        this.payFrom = payFrom;
        this.settlementId = settlementId;
        this.realTotalMoney = realTotalMoney;
        this.useScore = useScore;
        this.scoreMoney = scoreMoney;
        this.receiveTime = receiveTime;
        this.deliveryTime = deliveryTime;
        this.couponMoney = couponMoney;
        this.backMoney = backMoney;
        this.refundSrcStatus = refundSrcStatus;
        this.orderFrom = orderFrom;
    }

    public Integer getOrderId() {
        return orderId;
    }

    //getter setter方法
    public void setOrderId(Integer orderId) {
        this.orderId = orderId;
    }

    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    public Integer getOrderStatus() {
        return orderStatus;
    }

    public void setOrderStatus(Integer orderStatus) {
        this.orderStatus = orderStatus;
    }

    public Double getTotalMoney() {
        return totalMoney;
    }

    public void setTotalMoney(Double totalMoney) {
        this.totalMoney = totalMoney;
    }

    public Double getDeliverMoney() {
        return deliverMoney;
    }

    public void setDeliverMoney(Double deliverMoney) {
        this.deliverMoney = deliverMoney;
    }

    public Integer getPayType() {
        return payType;
    }

    public void setPayType(Integer payType) {
        this.payType = payType;
    }

    public Integer getIsSelf() {
        return isSelf;
    }

    public void setIsSelf(Integer isSelf) {
        this.isSelf = isSelf;
    }

    public Integer getIsPay() {
        return isPay;
    }

    public void setIsPay(Integer isPay) {
        this.isPay = isPay;
    }

    public Integer getDeliverType() {
        return deliverType;
    }

    public void setDeliverType(Integer deliverType) {
        this.deliverType = deliverType;
    }

    public Integer getUserAddressId() {
        return userAddressId;
    }

    public void setUserAddressId(Integer userAddressId) {
        this.userAddressId = userAddressId;
    }

    public Integer getOrderScore() {
        return orderScore;
    }

    public void setOrderScore(Integer orderScore) {
        this.orderScore = orderScore;
    }

    public Integer getIsInvoice() {
        return isInvoice;
    }

    public void setIsInvoice(Integer isInvoice) {
        this.isInvoice = isInvoice;
    }

    public String getInvoiceClient() {
        return invoiceClient;
    }

    public void setInvoiceClient(String invoiceClient) {
        this.invoiceClient = invoiceClient;
    }

    public String getOrderRemarks() {
        return orderRemarks;
    }

    public void setOrderRemarks(String orderRemarks) {
        this.orderRemarks = orderRemarks;
    }

    public Integer getIsAppraises() {
        return isAppraises;
    }

    public void setIsAppraises(Integer isAppraises) {
        this.isAppraises = isAppraises;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Integer getIsClosed() {
        return isClosed;
    }

    public void setIsClosed(Integer isClosed) {
        this.isClosed = isClosed;
    }

    public Integer getIsRefund() {
        return isRefund;
    }

    public void setIsRefund(Integer isRefund) {
        this.isRefund = isRefund;
    }

    public String getRefundRemark() {
        return refundRemark;
    }

    public void setRefundRemark(String refundRemark) {
        this.refundRemark = refundRemark;
    }

    public String getOrderunique() {
        return orderunique;
    }

    public void setOrderunique(String orderunique) {
        this.orderunique = orderunique;
    }

    public Integer getOrderSrc() {
        return orderSrc;
    }

    public void setOrderSrc(Integer orderSrc) {
        this.orderSrc = orderSrc;
    }

    public Integer getOrderFlag() {
        return orderFlag;
    }

    public void setOrderFlag(Integer orderFlag) {
        this.orderFlag = orderFlag;
    }

    public String getTradeNo() {
        return tradeNo;
    }

    public void setTradeNo(String tradeNo) {
        this.tradeNo = tradeNo;
    }

    public Integer getPayFrom() {
        return payFrom;
    }

    public void setPayFrom(Integer payFrom) {
        this.payFrom = payFrom;
    }

    public Integer getSettlementId() {
        return settlementId;
    }

    public void setSettlementId(Integer settlementId) {
        this.settlementId = settlementId;
    }

    public Double getRealTotalMoney() {
        return realTotalMoney;
    }

    public void setRealTotalMoney(Double realTotalMoney) {
        this.realTotalMoney = realTotalMoney;
    }

    public Integer getUseScore() {
        return useScore;
    }

    public void setUseScore(Integer useScore) {
        this.useScore = useScore;
    }

    public Double getScoreMoney() {
        return scoreMoney;
    }

    public void setScoreMoney(Double scoreMoney) {
        this.scoreMoney = scoreMoney;
    }

    public Date getReceiveTime() {
        return receiveTime;
    }

    public void setReceiveTime(Date receiveTime) {
        this.receiveTime = receiveTime;
    }

    public Date getDeliveryTime() {
        return deliveryTime;
    }

    public void setDeliveryTime(Date deliveryTime) {
        this.deliveryTime = deliveryTime;
    }

    public Integer getCouponMoney() {
        return couponMoney;
    }

    public void setCouponMoney(Integer couponMoney) {
        this.couponMoney = couponMoney;
    }

    public Double getBackMoney() {
        return backMoney;
    }

    public void setBackMoney(Double backMoney) {
        this.backMoney = backMoney;
    }

    public Integer getRefundSrcStatus() {
        return refundSrcStatus;
    }

    public void setRefundSrcStatus(Integer refundSrcStatus) {
        this.refundSrcStatus = refundSrcStatus;
    }

    public Integer getOrderFrom() {
        return orderFrom;
    }

    public void setOrderFrom(Integer orderFrom) {
        this.orderFrom = orderFrom;
    }


    public String toString() {
        return "Order [orderId=" + orderId + ", orderNo=" + orderNo + ", orderStatus=" + orderStatus + ", totalMoney=" + totalMoney + ", deliverMoney=" + deliverMoney + ", payType=" + payType + ", isSelf=" + isSelf + ", isPay=" + isPay + ", deliverType=" + deliverType + ", userAddressId=" + userAddressId + ", orderScore=" + orderScore + ", isInvoice=" + isInvoice + ", invoiceClient=" + invoiceClient + ", orderRemarks=" + orderRemarks + ", isAppraises=" + isAppraises + ", createTime=" + createTime + ", isClosed=" + isClosed + ", isRefund=" + isRefund + ", refundRemark=" + refundRemark + ", orderunique=" + orderunique + ", orderSrc=" + orderSrc + ", orderFlag=" + orderFlag + ", tradeNo=" + tradeNo + ", payFrom=" + payFrom + ", settlementId=" + settlementId + ", realTotalMoney=" + realTotalMoney + ", useScore=" + useScore + ", scoreMoney=" + scoreMoney + ", receiveTime=" + receiveTime + ", deliveryTime=" + deliveryTime + ", couponMoney=" + couponMoney + ", backMoney=" + backMoney + ", refundSrcStatus=" + refundSrcStatus + ", orderFrom=" + orderFrom + "]";
    }
}

